import type { Ref } from "vue";

export interface BaseWidgetType {
    id?:string;
    type: string;
    icon: string;
    options: {
        name: string;
        label: string;
        defaultValue: string;
        placeholder: string;
        readonly: boolean;
        disabled: boolean;
        clearable: boolean;
        required: boolean;
        requiredHint: string;
        validation: string;
        columnWidth: string;
        rules?:any[]
        picker?:string
    };
}

export interface DesignerType {
    widgets:Ref<BaseWidgetType[]>
    curWidget:Ref<BaseWidgetType | null>
    selectCurWidget:Function
    deleteWidget:Function
}